{extend name="base" /}
{block name="content"}
<div class="g-main">
    <div class="m-main-title">
        <div class="m-container-fluid">
            <a href="{:url('index/welcome')}"><i class="icon icon-home"></i>首页</a>
            <span class="icon-angle-right"></span>
            <span>商城</span>
            <span class="icon-angle-right"></span>
            <span>商品管理</span>
            <span class="icon-angle-right"></span>
            <span>供货商管理</span>
            <span class="icon-angle-right"></span>
            <span>{$info ? '编辑' : '添加'}供货商</span>
            <a class="u-flush"><i class="icon-repeat"></i></a>
        </div>
    </div>
    <div class="m-main-content">
        <div class="m-container">
            <div class="m-form">
                <form class="layui-form" id="j_form">
                    <table class="m-table">
                        <thead>
                            <tr>
                                <th colspan="2">{$info ? '编辑' : '添加'}供货商</th>
                            </tr>
                        </thead>
                        <tbody>
                            <tr>
                                <td width="15%"><label for="name">供货商名称<em>*</em></label></td>
                                <td><input type="text" class="u-ipt u-ipt-long" name="name" id="name" placeholder="请输入供货商名称" value="{$info.name}" /></td>
                            </tr>
                            <tr>
                                <td><label for="contact">联系人姓名<em>*</em></label></td>
                                <td><input type="text" class="u-ipt u-ipt-long" name="contact" id="contact" placeholder="请输入联系人姓名" value="{$info.contact}" /></td>
                            </tr>
                            <tr>
                                <td><label for="contact_phone">联系人电话<em>*</em></label></td>
                                <td><input type="text" class="u-ipt u-ipt-long" name="contact_phone" id="contact_phone" placeholder="请输入联系人电话" value="{$info.contact_phone}" /></td>
                            </tr>
                            <tr>
                                <td><label for="contact_address">联系人地址<em>*</em></label></td>
                                <td><input type="text" class="u-ipt u-ipt-long" name="contact_address" id="contact_address" placeholder="请输入联系人地址" value="{$info.contact_address}" /></td>
                            </tr>
                            <tr>
                                <td><label for="description">描述</label></td>
                                <td><div class="m-textarea"><textarea name="description" class="u-tarea" id="description" placeholder="请输入描述">{$info.description}</textarea></div></td>
                            </tr>
                            <tr>
                                <td><label for="list_order">排序</label></td>
                                <td><input type="text" class="u-ipt u-ipt-tiny" name="list_order" id="list_order" placeholder="请输入排序值" value="{$info.list_order|default=0}" /><span>值越大越排在前面</span></td>
                            </tr>
                        </tbody>
                    </table>
                    <div class="m-form-btn"><input type="hidden" name="id" value="{$info.id}"><button id="j_btn" class="u-btn">确定提交</button></div>
                </form>
            </div>
        </div>
    </div>
</div>
{/block}
{block name="extrajs"}
{include file="public:upload"/}
{/block}